package no.mehdi.game.repository;

import no.mehdi.game.domain.Player;

/**
 * Player repository interface
 * 
 * @author Mehdi Zare
 * 
 */
public interface PlayerRepository {
	/**
	 * Return the player by playerId
	 * 
	 * @param playerId
	 *            the playerId
	 * @return Player
	 */
	public Player getPlayerById(Long playerId);

	/**
	 * Get the player by name.
	 * 
	 * @param playerName
	 *            the playerName
	 * @return Player
	 */
	public Player getPlayerByName(String playerName);

	/**
	 * Save the player
	 * 
	 * @param player
	 *            player
	 */
	public void savePlayer(Player player);

	/**
	 * delete the player from DB.
	 * 
	 * @param player
	 *            player
	 */
	public void deletePlayer(Player player);

}
